import javax.swing.JFrame;
import javax.swing.JTabbedPane;

public class TabbedPane extends JFrame {
	JTabbedPane jTabbedPane;
	
	public TabbedPane() {
		jTabbedPane = new JTabbedPane(JTabbedPane.TOP);
		jTabbedPane.addTab("Tab1", null);
		jTabbedPane.addTab("Tab2", null);
		jTabbedPane.addTab("Tab3", null);
		jTabbedPane.setSize(300, 200);
		this.setTitle("TabbedPane(tanqi)");
		this.setSize(400, 160);
		this.setVisible(true);
		this.add(jTabbedPane);
	}
	
	public static void main(String[] args) {
		TabbedPane tp = new TabbedPane();
	}
}
